package com.ruicar.afs.cloud.common.mq.rabbit.anno.receiver;


import java.lang.annotation.*;

/**
 * The type AfsRabbitMqReceiver
 * <p>Description: </p>
 * 监听非平台内发送接收消息用，平台内部全部用通道级别注解
 *
 * @author Fzero
 * @version 1.0
 * @date Created on 2020.06.12 10:05:02
 * @since 1.0
 */
@Documented
@Inherited
@Retention(RetentionPolicy.RUNTIME)
@Target(ElementType.METHOD)
public @interface AfsRabbitMqReceiver {
    /**
     * Server alias string
     * 服务器别名与配置中一致
     *
     * @return the string
     */
    String serverAlias();

    /**
     * Queue name string
     * 监听队列名称
     *
     * @return the string
     */
    String queueName();

    /**
     * Target class class
     * 消息json 反序列化 class
     *
     * @return the class
     */
    Class targetClass() default Void.class;

    /**
     * Requeue boolean
     * 失败后是否重新添加进队列
     *
     * @return the boolean
     */
    boolean requeue() default false;
    String enableOn () default "";
}
